<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8" />
    <title></title>
    <link type="text/css" href="/css/core.css" rel="stylesheet"/>
    <link type="text/css" href="/layui/css/layui.css" rel="stylesheet">
    <link type="text/css" href="/css/main/module/msgboard/msgb.css" rel="stylesheet">
</head>
<body>
<div id="all">
    <div th:include="main/main_h :: main_head"></div>
    <div th:include="main/fitting/userinfo :: fitting_userinfo"></div>
    <div id="core">
        <div id="main">
            <div id="main_l">
                <div id="m_l_h">
                    <div id="mlh_l">
                        <span id="lyb">留言板</span>
                        <span id="lybcount" th:text="${msgBoards.size()}"></span>
                    </div>
                    <div id="mlh_r" th:if="${onchose==0}">
                        <span class="chose">最热</span>
                        |
                        <span onclick="onnew()">最新</span>
                    </div>
                    <div id="mlh_r" th:if="${onchose==1}">
                        <span onclick="onhot()">最热</span>
                        |
                        <span class="chose">最新</span>
                    </div>
                </div>
                <div id="m_l_m">
                    <div id="mlm_l">
                        <img id="lyuserimg" th:src="${user.user_img.file_path}+${user.user_img.file_name}"/>
                    </div>
                    <div id="mlm_r">
                        <textarea id="lynr" placeholder="你渴望拥有力量吗,留下留言让你强大"></textarea>
                    </div>
                    <div id="mlm_b" class="noshow">
                        <div id="yr_d">
                            <span>.</span>
                        </div>
                        <div id="send_d">
                            <button id="send" onclick="send()">发送</button>
                        </div>
                    </div>
                </div>

                <div id="m_l_b">
                    <div id="mlb_d">
                        <div th:each="msgBoard : ${msgBoards}">
                            <div class="mlb_l hover-div" th:grjj="${msgBoard.user.user_grjj}" th:username="${msgBoard.user.user_name}" th:userimg="${msgBoard.user.user_img.file_path}+${msgBoard.user.user_img.file_name}">
                                <img id="lyuserimg" th:src="${msgBoard.user.user_img.file_path}+${msgBoard.user.user_img.file_name}"/>
                            </div>
                            <div class="mlb_r">
                                <div class="mlbr_h">
                                    <span th:text="${msgBoard.user.user_name}"></span>
                                </div>
                                <div class="mlbr_m">
                                    <span th:text="${msgBoard.msg_content}"></span>
                                </div>
                                <div class="mlbr_b">
                                    <span th:text="${msgBoard.msg_time}"></span>
                                    <i th:id="${msgBoard.msg_id}+'up'" class="layui-icon layui-icon-praise" th:if="${msgBoard.isup==0}" th:onclick="|up('${msgBoard.msg_id}','${msgBoard.user.user_id}')|"></i>
                                    <i th:id="${msgBoard.msg_id}+'up'" class="layui-icon layui-icon-praise ischose" th:if="${msgBoard.isup!=0}" th:onclick="|up('${msgBoard.msg_id}','${msgBoard.user.user_id}')|"></i>
                                    <span th:id="${msgBoard.msg_id}+'upc'" th:text="${msgBoard.msg_upcount}"></span>
                                    <i th:id="${msgBoard.msg_id}+'down'" class="layui-icon layui-icon-tread" th:if="${msgBoard.isdown==0}" th:onclick="|down('${msgBoard.msg_id}','${msgBoard.user.user_id}')|"></i>
                                    <i th:id="${msgBoard.msg_id}+'down'" class="layui-icon layui-icon-tread ischose" th:if="${msgBoard.isdown!=0}" th:onclick="|down('${msgBoard.msg_id}','${msgBoard.user.user_id}')|"></i>
                                    <span th:id="${msgBoard.msg_id}+'downc'" th:text="${msgBoard.msg_downcount}"></span>
                                    <span class="hf" th:onclick="|hf('${msgBoard.msg_id}')|">回复</span>
                                </div>
                                <div class="hf_d">
                                    <div class="noshow hf_send_d" th:id="${msgBoard.msg_id}+'hf'">
                                        <div class="hf_m_l_m">
                                            <div class="hf_mlm_l">
                                                <img id="lyuserimg" th:src="${user.user_img.file_path}+${user.user_img.file_name}"/>
                                            </div>
                                            <div class="hf_mlm_r">
                                                <textarea th:id="${msgBoard.msg_id}+'lynr'" th:onclick="|toshow('${msgBoard.msg_id}')|" class="hf_lynr" th:placeholder="'@'+${msgBoard.user.getUser_name()+':'}"></textarea>
                                            </div>
                                            <div class="hf_mlm_b" th:id="${msgBoard.msg_id}+'hf_mlm_b'">
                                                <div class="hf_yr_d">
                                                    <span>.</span>
                                                </div>
                                                <div class="hf_send_dd">
                                                    <button class="hf_send" th:onclick="|hfsend('${msgBoard.msg_id}')|">发送</button>
                                                </div>
                                            </div>
                                        </div>
                                    </div>

                                    <div th:each="hfmsgBoard : ${msgBoard.hf_msgbds}">
                                        <div class="hf_mlb_l hover-div" th:grjj="${hfmsgBoard.user.user_grjj}" th:username="${hfmsgBoard.user.user_name}" th:userimg="${hfmsgBoard.user.user_img.file_path}+${hfmsgBoard.user.user_img.file_name}">
                                            <img id="hf_lyuserimg" th:src="${hfmsgBoard.user.user_img.file_path}+${hfmsgBoard.user.user_img.file_name}"/>
                                        </div>
                                        <div class="hf_mlb_r">
                                            <div class="hf_mlbr_h">
                                                <span th:id="${hfmsgBoard.msg_id}+'username'" th:text="${hfmsgBoard.user.user_name}"></span>
                                                <span class="hf_nr" th:text="${hfmsgBoard.msg_content}"></span>
                                            </div>
                                            <div class="hf_mlbr_b">
                                                <span th:text="${hfmsgBoard.msg_time}"></span>
                                                <i th:id="${hfmsgBoard.msg_id}+'up'" class="layui-icon layui-icon-praise" th:if="${hfmsgBoard.isup==0}" th:onclick="|up('${hfmsgBoard.msg_id}','${hfmsgBoard.user.user_id}')|"></i>
                                                <i th:id="${hfmsgBoard.msg_id}+'up'" class="layui-icon layui-icon-praise ischose" th:if="${hfmsgBoard.isup!=0}" th:onclick="|up('${hfmsgBoard.msg_id}','${hfmsgBoard.user.user_id}')|"></i>
                                                <span th:id="${hfmsgBoard.msg_id}+'upc'" th:text="${hfmsgBoard.msg_upcount}"></span>
                                                <i th:id="${hfmsgBoard.msg_id}+'down'" class="layui-icon layui-icon-tread" th:if="${hfmsgBoard.isdown==0}" th:onclick="|down('${hfmsgBoard.msg_id}','${hfmsgBoard.user.user_id}')|"></i>
                                                <i th:id="${hfmsgBoard.msg_id}+'down'" class="layui-icon layui-icon-tread ischose" th:if="${hfmsgBoard.isdown!=0}" th:onclick="|down('${hfmsgBoard.msg_id}','${hfmsgBoard.user.user_id}')|"></i>
                                                <span th:id="${hfmsgBoard.msg_id}+'downc'" th:text="${hfmsgBoard.msg_downcount}"></span>
                                                <span class="hf" th:onclick="|hfhf('${msgBoard.msg_id}','${hfmsgBoard.msg_id}')|">回复</span>
                                            </div>
                                        </div>
                                        <hr class="layui-border-black">
                                    </div>

                                    <div th:if="${msgBoard.hfcount>5}">
                                        <span class="hf_zk" th:text="共${msgBoard.hfcount}条回复 , 点击展开"></span>
                                    </div>

                                    <div class="noshow">
                                        <div class="hf_fy">
                                            <span>上一页</span>
                                            <span>1</span>
                                            <span>2</span>
                                            <span>3</span>
                                            <span>下一页</span>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <hr class="layui-border-black">
                        </div>
                    </div>
                </div>
            </div>
            <div id="main_r">

            </div>
        </div>
    </div>
</div>
</body>
<script src="/js/gj/jquery-3.5.1.min.js"></script>
<script src="/layui/layui.js"></script>
<script src="/js/main/module/msgboard/msgb.js"></script>
</html>